package com.jeff.tianti.cms.service;

import com.jeff.tianti.cms.entity.Constitution;
import com.jeff.tianti.cms.dao.ConstitutionDao;
import com.jeff.tianti.cms.dto.ConstitutionQueryDTO;
import com.jeff.tianti.common.service.CommonService;
import com.jeff.tianti.common.entity.PageModel;
import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
/**
 * @author NOW_GO
 * @desc ConstitutionService类 
 * @date 2019-07-11
 */
@Service
public class ConstitutionService extends CommonService< Constitution,String >  {

    @Autowired
    private ConstitutionDao constitutionDao;

    @Autowired
    public void setConstitutionDao(ConstitutionDao constitutionDao){
      super.setCommonDao(constitutionDao);
    }

    public PageModel<Constitution> queryConstitutionPage(ConstitutionQueryDTO constitutionQueryDTO){
           return this.constitutionDao.queryConstitutionPage(constitutionQueryDTO);
    }

    public List<Constitution> queryConstitutionList(ConstitutionQueryDTO constitutionQueryDTO){
           return this.constitutionDao.queryConstitutionList(constitutionQueryDTO);
    }

    public List<Map> queryList(ConstitutionQueryDTO constitutionQueryDTO){
        return this.constitutionDao.queryList(constitutionQueryDTO);
    }

    public List<Map<String, Object>> queryTitleList(String kewWord){
        return this.constitutionDao.queryTitleList(kewWord);
    }
}